package com.cloudkinto.vo.defective;

import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.util.Date;

@Data
public class DefectivePageDto {
    private Long id;
    private String defectiveNo;
    private Long whId;
    private Long companyId;
    private String companyName;
    private String companyCode;
    private String whCode;
    private String whNameCn;
    @ApiModelProperty("处理库存类型 1FNSKU(暂时不做) 2 SKU")
    private Integer stockKind;
    @ApiModelProperty("处理类型 1 次品出库 2次品销毁 3次品翻新")
    private Integer handleMethod;
    private String tips;
    private Integer status;

    @ApiModelProperty("收件人")
    private String receiver;
    @ApiModelProperty("电话")
    private String telephone;
    @ApiModelProperty("邮箱")
    private String email;
    @ApiModelProperty("收件人税号")
    private String taxNum;
    @ApiModelProperty("公司名称")
    private String comName;
    @ApiModelProperty("国家/公司")
    private String countryCode;
    @ApiModelProperty("省/州")
    private String provinceCode;
    @ApiModelProperty("城市名称")
    private String cityCode;
    @ApiModelProperty("邮编")
    private String postCode;
    @ApiModelProperty("门牌号")
    private String houseNum;
    @ApiModelProperty("地址1")
    private String addressOne;
    @ApiModelProperty("地址2")
    private String addressTwo;


    @ApiModelProperty("创建时间")
    private Date createTime;
    @ApiModelProperty("create_by")
    private Long createBy;
    private String createByName;
    @ApiModelProperty("提交")
    private Date submitTime;
    @ApiModelProperty("submit_by")
    private Long submitBy;
    private String submitByName;
    @ApiModelProperty("提交拣货")
    private Date submitPickTime;
    @ApiModelProperty("submit_pick_by")
    private Long submitPickBy;
    private String submitPickByName;
    @ApiModelProperty("拣货完成")
    private Date finishPickTime;
    @ApiModelProperty("finish_pick_by")
    private Long finishPickBy;
    private String finishPickByName;
    @ApiModelProperty("处理完成")
    private Date completeTime;
    @ApiModelProperty("complete_by")
    private Long completeBy;
    private String completeByName;
    @ApiModelProperty("取消时间")
    private Date cancelTime;
    @ApiModelProperty("cancel_by")
    private Long cancelBy;
    private String cancelByName;

    public String getHandleMethodName() {
        if (handleMethod == 1) {
            return "次品出库";
        }
        else if (handleMethod == 2) {
            return "次品销毁";
        }
        else if (handleMethod == 3) {
            return "次品翻新";
        }
        return "";
    }
}
